#include "Cell.h"

char CCell::GetType ()
{
	return m_type;
}

GColors CCell::GetColor ()
{
	return m_color;
}

void CCell::SetType (char type)
{
	m_type = type;

	//Set colour up to type
	if (m_type == 'r' || m_type == 'R')
	{
		m_color = GColors::LIGHT_RED;
	}
	else if (m_type == 'g' || m_type == 'G')
	{
		m_color = GColors::LIGHT_GREEN;
	}
	else if (m_type == 'b' || m_type == 'B')
	{
		m_color = GColors::LIGHT_BLUE;
	}
	else if (m_type == 'm' || m_type == 'M')
	{
		m_color = GColors::LIGHT_MAGENTA;
	}
	else if (m_type == 'y' || m_type == 'Y')
	{
		m_color = GColors::LIGHT_YELLOW;
	}
	else if (m_type == 'c' || m_type == 'C')
	{
		m_color = GColors::LIGHT_CYAN;
	}
	else if (m_type == 'l' || m_type == 'L')
	{
		m_color = GColors::LIGHT_BLACK;
	}
	else
	{
		m_color = LIGHT_WHITE;
	}
}